package com.boyunv.state.example01;
/*
 *@description
 *
 *@author boyunv
 *@create 2023/8/27 21:16
 *@version 1.0
 */

public class Client {
    public static void main(String[] args) {
        Context context = new Context();
        State concreteStateA = new ConcreteStateA();
        concreteStateA.handle(context);
        System.out.println(context.getCurrentState().toString());
        
        System.out.println("==============================");
        State concreteStateB = new ConcreteStateB();
        concreteStateB.handle(context);
        System.out.println(context.getCurrentState().toString());
    }
}
